    CKEDITOR.plugins.add( 'videoFrame_zhongzhh',
    {
    	requires : [ 'dialog','iframedialog', 'fakeobjects' ],
	    init : function( editor )
	    {
	    	var win,dialog,doc;
	    	editor.addCommand( 'videoFrame', new CKEDITOR.dialogCommand( 'videoFrame' ) );
	    	editor.ui.addButton( 'insertVideo',
	    {
	    	label : '插入视频',
			icon: 'images/insertVideo.png',
			command : 'videoFrame'
	    });
	    
	    var dialogDefinition =
			{
				buttons : [ CKEDITOR.dialog.okButton, CKEDITOR.dialog.cancelButton ],
				onOk: function(){
					win= this.getContentElement('iframe').getElement().$.contentWindow;
					if(win.obj.url== undefined){
						alert('请选择视频!');
						return false;
					}
					else{
						var result="<img src='"+win.obj.url+"' alt='"+win.obj.title+"'"+"/>";
						this.getParentEditor().insertHtml(result);
						
					}
				}
			};
			
	    CKEDITOR.dialog.addIframe( 'videoFrame', 'test','/resource/picture/search.do?gridMultiple=0&view=/resource/picture/selectpic&pageSize=10&fileTypes=jpg,gif,png',750,420,
	    	function(){
	    			},dialogDefinition
	    	)
	    }
    } );
